<?php

namespace App\Providers;

use Illuminate\Support\ServiceProvider;

class ViewsServiceProvider extends ServiceProvider
{
    /**
     * Register services.
     *
     * @return void
     */
    public function register()
    {
        //
    }

    /**
     * Bootstrap services.
     *
     * @return void
     */
    public function boot()
    {
        // view()->composer('layouts.app', function ($view) {
        //     $view->with([
        //          'total'=>30,
        //          'todoCount'=>40,
        //          'doneCount'=>100,
        //     ]);
               
        // });
        view()->composer('layouts.app', 'App\Http\ViewComposer\TaskCountComposer@compose');
    }
}
